import request from '@/utils/request'
import base from '@/api/base'

const noteApi = {
    ChunkUploadFile: base.outApi + '/file/ChunkUploadFile', //
}

/**
 * 分片测试
 * @returns
 */
export const ChunkUploadFileApi = (file, hash, name, partSize, ChunkCount, size, UploadId) => {
    const formData = new FormData();
    formData.append("files", file);
    formData.append("Name", name);
    formData.append("ID", hash);
    formData.append("PartSize", partSize);
    formData.append("ChunkCount", ChunkCount);
    formData.append("Size", size);
    formData.append("UploadId", UploadId);
    return request({
      url: noteApi.ChunkUploadFile,
      method: "post",
      data: formData,
      headersType: "multipart/form-data",
    });
  };